package com.neusoft.elmboot.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.neusoft.elmboot.mapper.UserCartMapper;
import com.neusoft.elmboot.po.User;
import com.neusoft.elmboot.po.UserCart;
import com.neusoft.elmboot.service.UserCartService;

@Service
public class UserCartServiceImpl implements UserCartService{
	@Autowired
	 private UserCartMapper usercartMapper;
	@Override
	public List<UserCart> listUserCart(){
		 return usercartMapper.listUserCart();
	 }
	
	@Override
	 public UserCart getUserCartByIdByPass(UserCart usercart) {
	 return usercartMapper.getUserCartByIdByPass(usercart);
	 }
	
	@Override
	 public int addUserById(UserCart usercart) {
		 return usercartMapper.addUserById(usercart);
	 }
	
	@Override
	 public UserCart getUserCartByUserId(UserCart usercart) {
	 return usercartMapper.getUserCartByUserId(usercart);
	 }
	
	@Override
	 public int subBalanceById(UserCart usercart) {
		 return usercartMapper.subBalanceById(usercart);
	 }
	
	@Override
	 public int updateAmountById(UserCart usercart) {
		 return usercartMapper.updateAmountById(usercart);
	 }

}
